package com.leetcode.LC;

import java.util.Arrays;

public class LC1619 {
    public double trimMean(int[] arr) {

        int sum=0;
        Arrays.sort(arr);
        int k= (int) (arr.length*0.05);
        for (int i = k; i < arr.length-k; i++) {
            sum+=arr[i];
        }
        return (sum*1.0)/(arr.length-2*k);
    }
}
